package cn.edu.wynu.oop.shape;

public class Round extends AbstractShape{
    // 半径
    float r;

    public Round(String name, float r) {
        super(name);
        this.r = r;
    }

    /**
     * 圆形计算面积方法
     * @return 面积
     */
    @Override
    public double returnSize() {
        return Math.PI * r * r;
    }
}
